fn djb2(s: &str) -> u64 {
    let mut hash_val: u64 = 5381;

    for c in s.as_bytes() {
        hash_val = ((hash_val << 5) + hash_val + *c as u64) & 0xFFFFFFFFFFFFFFFF;
    }

    hash_val
}

fn main() {
    
    let functions = vec![
        "NtCreateSection",
        "NtMapViewOfSection",
        "NtQueueApcThread",
        "NtResumeThread",
        "NtCreateThreadEx",
        "NtAllocateVirtualMemory",
        "NtWriteVirtualMemory",
        "NtProtectVirtualMemory",
        "NtOpenProcess",
        "NtClose",
        "NtWaitForSingleObject",
        "NtOpenThread",
        "NtGetContextThread",
        "NtSetContextThread",
        "NtSuspendThread",
        "NtTerminateProcess",
        "NtUnmapViewOfSection",
        "NtFreeVirtualMemory",
        "NtQueryInformationProcess",
        "NtQuerySystemInformation",
        "NtDelayExecution",
        "NtCreateUserProcess",
        "NtCreateProcessEx",
        "NtOpenSection",
        "NtMapViewOfSectionEx",
        "NtUnmapViewOfSectionEx",
        "NtCreateFile",
        "NtReadFile",
        "NtWriteFile",
        "NtDeviceIoControlFile",
        "RtlProcessHeap",
    ];

    for name in functions {
        let crypted = (djb2(name) ^ 0x41424344) & 0xFFFFFFFF;
        println!("const {}: u32 = 0x{:x};",  name, crypted);
    }
}
